package game;

import javax.media.opengl.GL;
import javax.media.opengl.glu.GLU;

import common.Point3D;




public class Camera {
	double fovy = 45.0;
	double znear = 0.1;
	double zfar = 1000;
	
	
	
	Point3D position = new Point3D(0,0,0);
	Point3D direction = new Point3D(0,0,0);
	

	public void paint(GL gl, int width, int height){
		gl.glPushMatrix();

		
		final GLU glu = new GLU();
	    gl.glViewport(0, 0, width, height);
	    gl.glMatrixMode(GL.GL_PROJECTION);
	    gl.glLoadIdentity();
	    glu.gluPerspective(fovy, (double)width / (double)height, znear, zfar);
	    gl.glMatrixMode(GL.GL_MODELVIEW);

	    gl.glPopMatrix();

	}


	public void updateView(GL gl) {
		// TODO Auto-generated method stub
	}
	
	public Point3D getPosition() {
		return position;
	}
	
	public Point3D getUp(){
		return new Point3D(0,1,0);
	}

	public void setPosition(Point3D position) {
		this.position = position;
	}



}
